		TITLE	FLLINNUM - Copyright (c) SLR Systems 1991

		INCLUDE	MACROS
		INCLUDE	MODULES

		PUBLIC	FLUSH_ERROR_LINENUMBERS

		.DATA

		.CODE	PASS2_TEXT

	SOFT	EXTP	RELEASE_BLOCK

		ASSUME	DS:NOTHING

FLUSH_ERROR_LINENUMBERS PROC
		;
		;DECREMENT COUNTS ON LINENUMBER RECORDS IF ERROR_LINENUMBERS
		;
		BITT	ERRORS_LINENUMBERS
		JZ	9$
		RESS	ERRORS_LINENUMBERS
		XOR	BX,BX
		;
		;FOR MODULE=FIRST THRU LAST
		;
		LDS	SI,FIRST_MODULE
		JMP	#TEST_MODULE

2$:
		CONV_DS
		PUSHM	[SI]._LN_NEXT_LINNUM.OFFS,[SI]._LN_NEXT_LINNUM.SEGM
		MOV	CX,[SI]._LN_SECOND_BLK
25$:
		DEC	WPTR [BX]
		JZ	5$
3$:
		JCXZ	4$
		MOV	DX,CX
		XOR	CX,CX
		MOV	DS,DX
		CONV_DS
		JMP	25$

4$:
		POPM	DS,SI
#TEST_LINE:
		MOV	DX,DS
		OR	DX,DX
		JNZ	2$
#NEXT_MODULE:
		POPM	DS,SI
#TEST_MODULE:
		MOV	CX,DS
		JCXZ	9$
1$:
		;
		;FOR LINE=FIRST_LINE THRU LAST LINE
		;
		SYM_CONV_DS
		PUSHM	[SI]._M_NEXT_MOD.OFFS,[SI]._M_NEXT_MOD.SEGM
;		LDS	SI,[SI]._M_FIRST_LIN
		JMP	#TEST_LINE

9$:
		FIXDS
		RET

5$:
		XCHG	AX,DX
		CALL	RELEASE_BLOCK
		JMP	3$

FLUSH_ERROR_LINENUMBERS ENDP

		END

